
letter = 'abcdefghijklmnopqrstuvwxyz'
c = 'lvueiakxudsyqehszqhykggsyylkvvi'

import libnum
f1=[i for i in range(1,26)]
f2=[i for i in range(1,26)]

for a in range(1,26):
    for b in range(1,26):
        flag = ''
        try:
            e=libnum.invmod(a,26)
            for i in c:
                flag += chr((e * (ord(i) - 97 - b) % 26) + 97)
            if "flag" in flag:
                print(flag)
                break
        except:
            continue
